package com.business.business.web.mapper;

import cn.hutool.json.JSONObject;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.business.business.model.InspectionWork;
import com.business.business.model.RelevantUnits;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

@Mapper
public interface InspectionWorkMapper extends BaseMapper<InspectionWork> {

    IPage<InspectionWork> inspectionworkListPageForOrg(IPage page, @Param("param") JSONObject jsonParam);

    IPage<InspectionWork> inspectionworkListPageForBu(IPage page, @Param("param") JSONObject jsonParam);

    InspectionWork getInspectionWorkById(JSONObject jsonParam);

    Map<String,Object> getFileField(JSONObject jsonParam);

    int getDistributionCount(JSONObject jsonParam);

    int getWorkableCount(JSONObject jsonParam);

    List<RelevantUnits> getRelevantUnitsList(JSONObject jsonParam);

    void insertAllUnits(List<RelevantUnits> list);

    List<Map<String,Object>> workableList(JSONObject jsonParam);
}
	